#define fbc -s console -a Resources\libfbpng.a

const MYBPP=32

#include "Modules\pload.bas"
#include "windows.bi"

SetPriorityClass(GetCurrentProcess,HIGH_PRIORITY_CLASS)

dim as any ptr IMGALP,IMGNOR,BACK
dim as integer NX,NY,MX,MY,MXX,MYY,FLAG
dim as string TECLA

screenres 800,600,MYBPP

BACK = Pload("graphics\back.png")
IMGALP = Pload("graphics\HD2-1.png")
'IMGNOR = Pload("graphics\HD2-3.png")

setmouse 400,300
MX=400:MY=300

do
  getmouse NX,NY
  if NX <> -1 and NY <> -1 then MX=NX:MY=NY
  screenlock
  put(0,0),BACK,pset
  
  MXX = (MXX*6+MX*2)/8
  MYY = (MYY*6+MY*2)/8
  
  if FLAG then
    put(MXX-120,MYY-240),IMGALP,alpha
  else
    put(MXX-120,MYY-240),IMGNOR,trans
  end if
  screenunlock
  
  sleep 10
    
  TECLA = inkey$
  if TECLA = chr$(13) then FLAG xor= 1
  if TECLA = chr$(27) then exit do
  
loop

